<link rel="stylesheet" type="text/css" href="../js/plugins/fileinput/css/jquery.filer.css" media="screen, projection">
<!--右边栏 Start-->
<div class="container-fluid" id="couponBody">
	<div class="row-fluid">
		<div class="span12">
			<div class="page-header fm-hd">
				<h4><span style="font-size:12px;">当前位置：营销工具&nbsp;&gt;&nbsp;</span>商品兑换券</h4>
			</div>
			<!-- 查询模块 Start -->
			<div class="fm-query">
				<div class="frmbox">
					<form id="excel" name="excel" style="display: none" method="post"></form>
					<form id="serchForm" name="serchForm">
						<div class="querybox">
							<div class="form-group">
								<label class="control-label">兑换券名称：</label>
								<div class="control-con">
									<input type="text" class="form-control" id="coupon_name" name="coupon_name" maxlength="30"/>
								</div>
							</div>
							<div class="form-group">
								<label class="control-label">关联商品名称：</label>
								<div class="control-con">
									<input type="text" class="form-control" id="goods_name" name="goods_name" maxlength="30"/>
								</div>
							</div>
							<div class="clearit"></div>
							<div class="form-group">
								<label class="control-label">配送次数：</label>
								<div class="control-con">
									<input type="text" class="form-control" id="delivery_times" name="delivery_times" datatype="/^\s*$/|/^[1-9]\d{1,2}$|^[0-9]$/"  errormsg="配送次数范围为[0-999]" maxlength="3" />
								</div>
							</div>
							<div class="form-group">
								<label class="control-label">商品价格：</label>
								<div class="control-con">
									<input type="text" class="form-control" id="goods_price" name="goods_price" datatype="/^\s*$/|/(^[+]?[1-9]\d{0,4}(\.\d{1,2})?$)|(^[+]?[0]{1}(\.\d{1,2})?$)/"  errormsg="价格范围在【0-99999.99】" maxlength="8"/>
								</div>
							</div>
							<div class="clearit"></div>
							<div class="form-group">
                                <label class="control-label">使用有效期：</label>
                                <div class="control-con">
                                	<input type="text" class="form-control w130" id="first_valid_date" name="first_valid_date" data-date-format="yyyy-mm-dd" readonly="readonly"  onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'last_valid_date\')||\'\'}'})"><span class="w40">到</span>
                                	<input type="text" class="form-control w130" id="last_valid_date" name="last_valid_date" data-date-format="yyyy-mm-dd" readonly="readonly" onFocus="WdatePicker({minDate:'#F{$dp.$D(\'first_valid_date\')||\'\'}'})">
                                </div>
                                <div class="help-block with-errors"></div>
                            </div>
							<div class="form-group">
								<label class="control-label">状态：</label>
								<div class="control-con">
									<select class="form-control" id="coupon_status" name="coupon_status">
										<option value>全部</option>
										<option value="1">未开始</option>
										<option value="2">进行中</option>
										<option value="3">已过期</option>
									</select>
								</div>
							</div>
							<div class="clearit"></div>
						</div>
						<div class="querybtn">
							<button class="btn btn-primary serchBtn" type="button">搜索</button>
							<button class="btn btn-default resetBtn" type="button">重置</button>
						</div>
					</form>
				</div>
			</div>
			<!-- 查询模块 End -->
			<!-- 兑换券列表 Start -->
			<div class="order-list">
				<h4>
					<button class="btn btn-primary editCoupon" id="addCoupon">
						新增兑换券
					</button>
				</h4>
				<div class="dddbox" id="coupon_list">
					<table class="table table-striped ddd-table" style="display: none">
						<thead>
							<tr>
								<th>兑换券名称</th>
								<th>关联商品名称</th>
								<th>配送次数</th>
								<th>商品价格</th>
								<th>使用有效期</th>
								<th>已使用/总数</th>
								<th>状态</th>
								<th>操作</th>
							</tr>
						</thead>
						<tbody>
							<col width="15%"></col>
							<col width="20%"></col>
							<col width="10%"></col>
							<col width="10%"></col>
							<col width="10%"></col>
							<col width="10%"></col>
							<col width="10%"></col>
							<col width="15%"></col>
							<tr>
								<td>兑换券一</td>
								<td>测试商品一6斤装</td>
								<td>8次</td>
								<td>388</td>
								<td>2016/12/01~2016/12/31</td>
								<td>5 / 10</td>
								<td><span class="f-green">进行中</span></td>
								<td>
									<a href="#" data-toggle="modal" data-target="#viewCoupon">查看兑换券</a><a href="#" class="mlr10" data-toggle="modal" data-target="#editCoupon">编辑</a><a href="#">删除</a>
								</td>
							</tr>
							<tr>
								<td>兑换券一</td>
								<td>测试商品一6斤装</td>
								<td>8次</td>
								<td>388</td>
								<td>2016/12/01~2016/12/31</td>
								<td>5 / 10</td>
								<td>
									<span class="f-red">已过期</span>
								</td>
								<td>
									<a href="#" data-toggle="modal" data-target="#viewCoupon">查看兑换券</a><a href="#" class="mlr10" data-toggle="modal" data-target="#editCoupon">编辑</a><a href="#">删除</a>
								</td>
							</tr>
							<tr>
								<td>兑换券一</td>
								<td>测试商品一6斤装</td>
								<td>8次</td>
								<td>388</td>
								<td>2016/12/01~2016/12/31</td>
								<td>5 / 10</td>
								<td>
									<span class="f-gray">未开始</span>
								</td>
								<td>
									<a href="#" data-toggle="modal" data-target="#viewCoupon">查看兑换券</a><a href="#" class="mlr10" data-toggle="modal" data-target="#editCoupon">编辑</a><a href="#">删除</a>
								</td>
							</tr>
						</tbody>
					</table>
				</div>
				<!-- 兑换券列表 End -->
				<!-- 分页 Start -->
				<div class="pagebox" id="pageBox" style="display: none">
					<div class="numbox">共<span class="blue3" id="records">8</span>条记录</div>
					<ul class="pagination fm_pageination" id="page">
						<li>
							<a href="#">上一页</a>
						</li>
						<li class="active">
							<a href="#">1</a>
						</li>
						<li>
							<a href="#">2</a>
						</li>
						<li>
							<a href="#">3</a>
						</li>
						<li>
							<a href="#">4</a>
						</li>
						<li>
							<a href="#">5</a>
						</li>
						<li>
							<a href="#">下一页</a>
						</li>
					</ul>
				</div>
				<!-- 分页 End -->
			</div>
		</div>
	</div>
	<!--右边栏 End-->

	<!-- 消息提示框  -->
	<div class="mes-container" id="msg_dialog">
	</div>
	

	<!-- 添加编辑兑换券模态框（Modal） -->
	<div class="modal fade" id="coupon_modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true" data-backdrop="static">
		<div class="modal-dialog" id="coupon_content">
			
		</div>
	</div>